<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml"
	  xmlns:th="http://www.thymeleaf.org"
	  xmlns:sec="http://www.thymeleaf.org/extras/spring-security">
<head>
	<meta charset="utf-8">
	<title>系统中心</title>
	<meta name="renderer" content="webkit">
	<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
	<meta http-equiv="Access-Control-Allow-Origin" content="*">
	<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
	<meta name="apple-mobile-web-app-status-bar-style" content="black">
	<meta name="apple-mobile-web-app-capable" content="yes">
	<meta name="format-detection" content="telephone=no">
	<link rel="icon" th:href="@{/favicon.ico}">
	<link rel="stylesheet" th:href="@{/js/layui-v2.4.5/layui/css/layui.css}" media="all" />
	<link rel="stylesheet" th:href="@{/css/index.css}" media="all" />

</head>
<body class="main_body"  style="-webkit-backface-visibility: hidden;">
<style>
	.layui-tab {
		margin: 0 !important;
	}
</style>
	<div class="layui-layout layui-layout-admin">
		<!-- 顶部 -->
		<div class="layui-header header">
			<div class="layui-main mag0">
				<a class="logo">客户管理系统</a>
				<!-- 显示/隐藏菜单 -->
				<a href="javascript:;" class="seraph hideMenu icon-caidan"></a>
				<!-- 顶级菜单 -->
				<ul class="layui-nav mobileTopLevelMenus" mobile>
					<li class="layui-nav-item" data-menu="contentManagement">
						<a href="javascript:;"><i class="seraph icon-caidan"></i><cite>选择功能</cite></a>
						<dl class="layui-nav-child" id="top_parent_mobile">
							<!--<dd class="layui-this" data-menu="contentManagement"><a href="javascript:;"><i class="layui-icon" data-icon="&#xe63c;">&#xe63c;</i><cite>内容管理</cite></a></dd>-->
							<!--<dd class="layui-this" data-menu="productManagement" ><a href="javascript:;"><i class="layui-icon" data-icon="&#xe63c;">&#xe63c;</i><cite>商品中心</cite></a></dd>-->
							<!--<dd data-menu="orderManagement"><a href="javascript:;"><i class="seraph icon-icon10" data-icon="icon-icon10"></i><cite>订单中心</cite></a></dd>-->
							<!--<dd data-menu="memberCenter"><a href="javascript:;" ><i class="seraph icon-icon10" data-icon="icon-icon10"></i><cite>用户中心</cite></a></dd>-->
							<!--<dd data-menu="systemeSttings"><a href="javascript:;" ><i class="layui-icon" data-icon="&#xe620;">&#xe620;</i><cite>系统设置</cite></a></dd>-->
						</dl>
					</li>
				</ul>
				<ul class="layui-nav topLevelMenus" pc id="top_parent_pc">
					<!--<li class="layui-nav-item layui-this" data-menu="contentManagement">
						<a href="javascript:;"><i class="layui-icon" data-icon="&#xe63c;">&#xe63c;</i><cite>内容管理</cite></a>
					</li>-->
					<!--<li class="layui-nav-item layui-this" data-menu="productManagement" >-->
						<!--<a href="javascript:;"><i class="layui-icon" data-icon="&#xe63c;">&#xe63c;</i><cite>商品中心</cite></a>-->
					<!--</li>-->
					<!--<li class="layui-nav-item" data-menu="orderManagement" pc>-->
						<!--<a href="javascript:;"><i class="seraph icon-icon10" data-icon="icon-icon10"></i><cite>订单中心</cite></a>-->
					<!--</li>-->
					<!--<li class="layui-nav-item" data-menu="memberCenter" pc >-->
						<!--<a href="javascript:;"><i class="seraph icon-icon10" data-icon="icon-icon10"></i><cite>用户中心</cite></a>-->
					<!--</li>-->
					<!--<li class="layui-nav-item" data-menu="systemeSttings" pc >-->
						<!--<a href="javascript:;"><i class="layui-icon" data-icon="&#xe620;">&#xe620;</i><cite>系统设置</cite></a>-->
					<!--</li>-->
					<!--<li class="layui-nav-item" data-menu="seraphApi" pc >
						<a href="javascript:;"><i class="layui-icon" data-icon="&#xe705;">&#xe705;</i><cite>使用文档</cite></a>
					</li>-->
				</ul>
			    <!-- 顶部右侧菜单 -->
			    <ul class="layui-nav top_menu">
					<!--<li class="layui-nav-item" pc>-->
					<li class="layui-nav-item lockcms" pc>
						<!--<a href="javascript:;"><i class="seraph icon-lock"></i><cite>锁屏</cite></a>-->
					</li>
					<li class="layui-nav-item" id="userInfo">
						<a href="javascript:;"><img th:src="@{/images/face.jpg}" class="layui-nav-img userAvatar" width="35" height="35"><cite class="adminName" th:text="${userInfo?.name}"/></a>
						<dl class="layui-nav-child">
							<dd id = "password"><a href="javascript:" data-url=""><i class="seraph icon-xiugai" data-icon="icon-xiugai"></i><cite>修改密码</cite></a></dd>
							<!--<dd><a href="javascript:;" class="showNotice"><i class="layui-icon">&#xe645;</i><cite>系统公告</cite><span class="layui-badge-dot"></span></a></dd>-->
							<dd><a class="signOut" onclick="out()"><i class="seraph icon-tuichu"></i><cite>退出</cite></a></dd>

						</dl>
					</li>
				</ul>
			</div>
		</div>
		<!-- 左侧导航 -->
		<div class="layui-side layui-bg-black">
			<div class="user-photo">
				<a class="img" title="我的头像" ><img th:src="@{/images/face.jpg}" class="userAvatar"></a>
				<p>你好！<span class="userName" th:text="${userInfo?.name}"/>, 欢迎登录</p>
			</div>
			<div class="navBar layui-side-scroll" id="navBar">
				<ul class="layui-nav layui-nav-tree">
					<li class="layui-nav-item layui-this">
						<a href="javascript:;" data-url="page/main.html"><i class="layui-icon" data-icon=""></i><cite>首页</cite></a>
					</li>
				</ul>
			</div>
		</div>
		<!-- 右侧内容 -->

		<!-- 右侧内容 -->
		<div class="layui-body layui-form">
			<div class="layui-tab mag0" lay-filter="bodyTab" id="top_tabs_box" style=" margin: 0;">
				<ul class="layui-tab-title top_tab" id="top_tabs">
					<li class="layui-this" lay-id=""><i class="layui-icon">&#xe68e;</i><cite>首页</cite></li>
				</ul>
				<ul class="layui-nav closeBox">
					<li class="layui-nav-item">
						<a href="javascript:;"><i class="layui-icon caozuo">&#xe643;</i> 页面操作</a>
						<dl class="layui-nav-child">
							<dd><a href="javascript:;" class="refresh refreshThis"><i class="layui-icon">&#x1002;</i> 刷新当前</a></dd>
							<dd><a href="javascript:;" class="closePageOther"><i class="seraph icon-prohibit"></i> 关闭其他</a></dd>
							<dd><a href="javascript:;" class="closePageAll"><i class="seraph icon-guanbi"></i> 关闭全部</a></dd>
						</dl>
					</li>
				</ul>
				<div class="layui-tab-content clildFrame">
					<div class="layui-tab-item layui-show">
						<iframe th:src="@{/main}"></iframe>
					</div>
				</div>
			</div>
		</div>
		<!-- 底部 -->
		<div class="layui-footer footer">
		</div>
	</div>

	<!-- 移动导航 -->
	<div class="site-tree-mobile"><i class="layui-icon">&#xe602;</i></div>
	<div class="site-mobile-shade"></div>
	<script th:src="@{/js/layui-v2.4.5/layui/layui.js}"></script>
	<script th:src="@{/js/jquery-1.7.2.min.js}"></script>
	<script th:src="@{/js/utils.js}"></script>
	<script type="text/javascript" th:src="@{/js/index.js}"></script>
	<script type="text/javascript" th:src="@{/js/cache.js}"></script>


<script th:inline="javascript">
    var myLogoutUri = [[${myLogoutUri}]];


		/**
		 * 这里要依次遍历登出所有系统
		 * */
		function out() {
		    console.log("登出......")
			if(myLogoutUri!=null&&myLogoutUri.length>0){
		        for(var i=0;i<myLogoutUri.length;i++){
                    $.ajax({
                        type: "get",
                        url: myLogoutUri[i],
                        data:{
                        },
                        xhrFields:{withCredentials:true}
                    });
				}
			}
			standardPost(path+"/logout",[]);
        }


        /**
		 * 这里有模拟提交
         * @param url
         * @param args
         */
        function standardPost(url,args){
            var form = $("<form method='post'></form>"),
                input;
            form.attr({"action":url});
            $.each(args,function(key,value){
                input = $("<input type='hidden'>");
                input.attr({"name":key});
                input.val(value);
                form.append(input);
            });
            $(document.body).append(form);
            form.submit();
        }

	</script>
</body>
</html>